Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: Add test for "needCheckForUpdates" #82

Closed
wants to merge 2 commits into from

Conversation

tanishiking
Copy link
Owner

@tanishiking tanishiking commented Sep 1, 2022

This commit adds a test for needCheckForUpdates.
(because, even though metals-vscode has a complicated logic, it lacks
unit-tests to verify the behaviors).

For adding unit tests, this commit abstract away the logics that need
an access to vscode APIs, becuase we need to run integration test for
accessing vscode APIs.
see: microsoft/vscode-wordcount#5 (comment)
microsoft/vscode#82471 (comment)

@kpodsiad
Copy link

kpodsiad commented Sep 1, 2022

It's awesome that you're trying to tackle this @tanishiking. I'll have a look at it later today ;)

@tanishiking
Copy link
Owner Author

thanks! I'll open a PR against scalameta :)

@kpodsiad
Copy link

kpodsiad commented Sep 1, 2022

One problem with assert is that it doesn't provide meaningful error messages. I was thinking about using earl, wdyt?

@tanishiking tanishiking force-pushed the test-need-check-update branch from 57e701d to a2f1cd1 Compare September 2, 2022 03:58
scalameta#1144

This commit adds a test for `needCheckForUpdates`.

For adding unit tests, this commit abstract away the logic that needs
access to vscode APIs, becuase we need to run an integration test for
accessing vscode APIs.
see: microsoft/vscode-wordcount#5 (comment)
microsoft/vscode#82471 (comment)
@tanishiking tanishiking force-pushed the test-need-check-update branch from cf2862e to 8c28bbf Compare September 2, 2022 04:25
@tanishiking tanishiking closed this Sep 2, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants